import { Spin } from 'antd';
import { useEffect,useState } from 'react';
import { LoadingOutlined } from '@ant-design/icons';

export const Loading = () => {
   const [height,setHeight] = useState(0);
    useEffect(() => {
        setHeight(window.innerHeight-document.getElementsByClassName("header")[0].clientHeight);
    }, []);
    return (
        <div className="loading" style={{height:height + 'px'}}>
            <Spin indicator={<LoadingOutlined style={{ fontSize: 40 }} />} /> 
        </div>
    )
}